﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Input;
using Sparkle.Demo.Model;
using Sparkle.MVVM;
using Sparkle.MVVM.ActionResults;
using Sparkle.Wpf.Demo.UI.Attributes;

namespace Sparkle.Wpf.Demo.UI
{
    [LinkDocuments("Test LinkDoc",1)]
    [LinkNotes("Test Link Notes", 2)]
    public class PersonController : BaseController<Employee>
    {
        private Employee _employee = new Employee();

        public Employee Employee
        {
            get { return _employee; }
            set { _employee = value; } 
        }

        public PersonController()
        {
            //SaveCommand = new Command(SaveEmployee);
        }



        public IActionResult SaveEmployee()
        {
            return new EmptyActionResult();
        }

        public ICommand SaveCommand { get; set; }

        public void NewEmployee()
        {
            Model = new Employee() ;
        }

        public override string ToString()
        {
            return string.Format("{0} {1}", Employee.FName, Employee.LName);
        }
    }
}
